<template>
  <div>
    <h3>this is goods</h3>
    <nuxt-link to="/goods/one">one</nuxt-link>
    <nuxt-link to="/goods/two">two</nuxt-link>
    <br />
    <nuxt-link to="/goods/1">detail 01</nuxt-link>
    <nuxt-link to="/goods/1?a=1&b=2">detail 02</nuxt-link>
    <nuxt-link :to="{name:'goods-id',params:{id:3},query:{a:3,b:3}}">detail 03</nuxt-link>
    <nuxt />
  </div>
</template>

<script>
  export default {
    transition: 'test',
    // beforeRouteLeave(to,from,next){
    //   next(window.confirm("是否离开"))
    // }
  }
</script>

<style>
/*  .test-enter-active,
  .test-leave-active {
    transition: 2s ease all;
  }

  .test-enter,
  .test-leave-active {
    margin-left: 500px;
  } */
</style>
